package com.ruleengine.instruction.impl;

import com.ruleengine.instruction.InstructionType;

public class ConditionInstruction extends BaseInstruction {
    private String expression;
    private int gotoOffset;

    public ConditionInstruction() {
        super(InstructionType.CONDITION);
    }
    

    /**
     * @return the expression
     */
    public String getExpression() {
        return expression;
    }


    /**
     * @param expression the expression to set
     */
    public void setExpression(String expression) {
        this.expression = expression;
    }


    public int getGotoOffset() {
        return gotoOffset;
    }

    public void setGotoOffset(int offset) {
        gotoOffset = offset;
    }

    @Override
    public String toString() {
        return "{" + super.toString() + "," + expression +"," + gotoOffset+"}";
    }

}
